package com.langsin.ArrayDemo;

/**
 * @Auther: MFM
 * @Date: 2021/7/15 - 07 - 15 - 20:03
 * @version: 1.0
 */

public class Student {
    private String name;
    private int score;

    public Student(String name, int score) {
        this.name = name;
        this.score = score;
    }

    @Override
    public String toString() {
        return String.format("Student:name-" + name + "\tscore-" + score + "\n");

    }

    public static void main(String[] args) {
        Array<Student> arr = new Array<Student>();
        arr.addLast(new Student("张三",100));
        arr.addLast(new Student("李四",55));
        arr.add(1,new Student("王五",38));
        System.out.println(arr);
    }
}
